package com.yanqu.road.entity.log.kowloon;

import com.yanqu.road.entity.FieldTypeAnnotation;
import com.yanqu.road.entity.log.ServerBaseLog;

import java.sql.Types;
import java.util.Date;

@FieldTypeAnnotation(tableName = "t_l_ck_kowloon_merge", desc = "九龙城寨-合成日志", autoSave = true, uploadCk = true)
public class LogKowloonMerge extends ServerBaseLog {

    @FieldTypeAnnotation(desc = "用户ID", isIndex = true)
    private long userId;

    @FieldTypeAnnotation(desc = "关卡id")
    private int chapterId;

    @FieldTypeAnnotation(desc = "波次")
    private int sectionId;

    @FieldTypeAnnotation(desc = "操作类型")
    private int operateType;

    @FieldTypeAnnotation(desc = "操作位置")
    private String operatePosition;

    @FieldTypeAnnotation(desc = "连消次数")
    private int eliminateAmount;

    @FieldTypeAnnotation(desc = "获得技能")
    private int skillId;

    @FieldTypeAnnotation(desc = "合成好汉map", sqlType = Types.LONGNVARCHAR)
    private String mergeHeroMap;

    @FieldTypeAnnotation(desc = "合成福袋map", sqlType = Types.LONGNVARCHAR)
    private String mergeSkillMap;

    @FieldTypeAnnotation(desc = "累计获得技能map", sqlType = Types.LONGNVARCHAR)
    private String skillMap;

    @FieldTypeAnnotation(desc = "福袋获得步数")
    private int skillAddStep;

    @FieldTypeAnnotation(desc = "福袋获得步数")
    private int eliminateAddStep;

    @FieldTypeAnnotation(desc = "操作步数")
    private int useStep;

    @FieldTypeAnnotation(desc = "剩余步数")
    private int leftStep;

    @FieldTypeAnnotation(desc = "时间")
    private Date addTime;

    public LogKowloonMerge(long userId, int chapterId, int sectionId, int operateType, String operatePosition, int eliminateAmount, int skillId, String mergeHeroMap, String mergeSkillMap, String skillMap, int skillAddStep, int eliminateAddStep, int useStep, int leftStep) {
        this.userId = userId;
        this.chapterId = chapterId;
        this.sectionId = sectionId;
        this.operateType = operateType;
        this.operatePosition = operatePosition;
        this.eliminateAmount = eliminateAmount;
        this.skillId = skillId;
        this.mergeHeroMap = mergeHeroMap;
        this.mergeSkillMap = mergeSkillMap;
        this.skillMap = skillMap;
        this.skillAddStep = skillAddStep;
        this.eliminateAddStep = eliminateAddStep;
        this.useStep = useStep;
        this.leftStep = leftStep;
        this.addTime = new Date();
    }

    @Override
    public long getUserId() {
        return userId;
    }
}
